Skip to content

Conversation

@manuzhang
Copy link
Member

Which issue does this PR close?

Closes #2685.

Rationale for this change

What changes are included in this PR?

How are these changes tested?

@codecov-commenter
Copy link

codecov-commenter commented Nov 4, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 59.30%. Comparing base (f09f8af) to head (4066df0).
⚠️ Report is 658 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main    #2686      +/-   ##
============================================
+ Coverage     56.12%   59.30%   +3.17%     
- Complexity      976     1436     +460     
============================================
  Files           119      147      +28     
  Lines         11743    13796    +2053     
  Branches       2251     2369     +118     
============================================
+ Hits           6591     8182    +1591     
- Misses         4012     4388     +376     
- Partials       1140     1226      +86     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@coderfender
Copy link
Contributor

coderfender commented Nov 5, 2025

This is awesome ! @manuzhang


if [ ! -f "${COMET_SPARK_JAR}" ]; then
echo "Building Comet Spark jar..."
cd ..
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also be building native code here ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm following instructions in README to run mvn install -DskipTests at the root level. Which flag is also needed?

#

set -eu

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You may want to add some logic to detect the current working directory.
At the moment this script assumes that it is called with ./run.sh but some user may try to run it from the parent folder with ./fuzz-testing/run.sh.


SPARK_MASTER="${SPARK_MASTER:-local[*]}"
PROJECT_VERSION="$(mvn -q help:evaluate -Dexpression=project.version -DforceStdout)"
COMET_SPARK_JAR="../spark/target/$(mvn -f ../spark/pom.xml -q help:evaluate -Dexpression=project.artifactId -DforceStdout)-${PROJECT_VERSION}.jar"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be cleaner and easier to debug (with set -x) if you extract the sub-shell commands and assign their results to their own variables.
E.g.

SPARK_ARTIFACT_ID="$(mvn -f ../spark/pom.xml -q help:evaluate -Dexpression=project.artifactId -DforceStdout)"
FUZZ_ARTIFACT_ID="$(mvn -q help:evaluate -Dexpression=project.artifactId -DforceStdout)"
COMET_SPARK_JAR="../spark/target/${SPARK_ARTIFACT_ID}-${PROJECT_VERSION}.jar"
COMET_FUZZ_JAR="target/${FUZZ_ARTIFACT_ID}-${PROJECT_VERSION}-jar-with-dependencies.jar"

echo "Building Comet Spark jar..."
cd ..
mvn install -DskipTests
cd fuzz-testing
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can avoid navigating the folders with cd by using mvn -f ../pom.xml ...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be done once #2691 is in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CometFuzz] Add script to build and run fuzz testing

4 participants